package cn.ywsj.ywsjmidtier.service;

import cn.ywsj.ywsjmidtier.common.Connect;
import cn.ywsj.ywsjmidtier.entity.VO.CaptchaVo;
import com.alibaba.fastjson.JSONObject;
import feign.Response;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.MediaType;
import org.springframework.util.MultiValueMap;
import org.springframework.validation.BindingResult;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;

import javax.servlet.http.HttpSession;

/**
 * @ClassName : CaptchaFeign
 * @Author : Lenovo
 * @Date: 2021/7/19 11:09
 * @Description :
 */
@FeignClient(url = Connect.XSX_URL,name = "xsx")
public interface CaptchaFeign {
    @RequestMapping(value ="/captcha/sendcode",method = RequestMethod.POST,consumes = MediaType.APPLICATION_FORM_URLENCODED_VALUE)
    String sendCode(@RequestParam("captchaVo") JSONObject captchaVo, @RequestParam("result") BindingResult result, @RequestParam("session") HttpSession session);
    @PostMapping("/captcha/getimageverifycode")
    Response getimageverifycode();
}
